//
//  FlowLayout.h
//  WaterFall1109
//
//  Created by Mr、J on 15/11/9.
//  Copyright © 2015年 chenjun. All rights reserved.
//

#import <UIKit/UIKit.h>


@protocol CJCollectionViewFlowlayout <UICollectionViewDelegateFlowLayout>


//重写系统的协议方法，获取每个item的大小
-(CGSize)collectionview:(UICollectionView *)collectionView layout:(UICollectionViewLayout *)collectionViewLayout sizeForItemAtItemIndexPath:(NSIndexPath *)indexPath;

@end



@interface FlowLayout : UICollectionViewLayout

@property (nonatomic, assign) id <CJCollectionViewFlowlayout>delegate;

//保存布局信息
@property (nonatomic, retain) NSMutableArray *array;

//记录当前contentView的大小
@property (nonatomic, assign) CGFloat maxHeight;


@end
